package com.example.june.zhanghaoguanli;

import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.widget.ListView;

import com.longfly_example.e_scale.R;

import java.util.ArrayList;
import java.util.List;

public class Activity_xsjl extends AppCompatActivity {

    ListView myListView ;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_xsjl);
        List<LianxirenBean> itemBeanList = new ArrayList<LianxirenBean>();

        itemBeanList.add(new LianxirenBean("苹果","1200","9.9","1880","001"));
        itemBeanList.add(new LianxirenBean("草莓","665","8.9","3724","003"));
        itemBeanList.add(new LianxirenBean("橙子","540","12.9","4806","010"));
        itemBeanList.add(new LianxirenBean("柠檬","43","8.9","554.7","005"));
        itemBeanList.add(new LianxirenBean("葡萄","55","15.9","825","008"));
        itemBeanList.add(new LianxirenBean("雪梨","1324","6.9","5958","007"));
        itemBeanList.add(new LianxirenBean("香蕉","343","3.9","1474.9","009"));

        myListView =(ListView)findViewById(R.id.lv_xsjl);
        //设置ListView的数据适配器
        myListView.setAdapter(new Myadapter_xsjl(this,itemBeanList));
    }
}
